<?php

namespace common\models\db\tables;

use Yii;

/**
 * This is the model class for table "{{%log_send_to_fzt}}".
 *
 * @property int $id
 * @property string $trans_id 请求业务流水号
 * @property string $route 接口地址
 * @property string|null $route_name 接口地址说明
 * @property string $version 版本
 * @property string $plat_no 平台编号
 * @property string|null $plat_cust_no 客户编号
 * @property string|null $rand_key 随机密钥
 * @property string $pre_encryption_data 加密前请求数据
 * @property string|null $serial_no 技术报文序列号
 * @property string|null $technology_message 技术报文
 * @property int $created_at
 * @property int $updated_at
 * @property int|null $deleted_at
 * @property int|null $created_by
 * @property int|null $updated_by
 * @property int $status
 * @property string|null $resp 响应信息
 * @property string|null $ret_code 返回码
 * @property string|null $ret_msg 返回结果描述
 * @property string|null $for_model_class 对应的模型
 * @property int|null $for_model_id 对应的模型ID
 */
class LogSendToFzt extends \yii\db\ActiveRecord
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return '{{%log_send_to_fzt}}';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['trans_id', 'route', 'route_name', 'version', 'plat_no', 'plat_cust_no', 'rand_key', 'pre_encryption_data', 'serial_no', 'technology_message', 'created_at', 'updated_at', 'deleted_at', 'created_by', 'updated_by', 'status', 'resp', 'ret_code', 'ret_msg', 'for_model_class', 'for_model_id'], 'trim'],
            [['trans_id', 'route', 'version', 'plat_no', 'pre_encryption_data', 'created_at', 'updated_at'], 'required'],
            [['pre_encryption_data', 'technology_message', 'resp'], 'string'],
            [['created_at', 'updated_at', 'deleted_at', 'created_by', 'updated_by', 'status', 'for_model_id'], 'integer'],
            [['trans_id', 'plat_cust_no'], 'string', 'max' => 32],
            [['route', 'route_name', 'version'], 'string', 'max' => 10],
            [['plat_no', 'rand_key', 'serial_no'], 'string', 'max' => 50],
            [['ret_code', 'ret_msg'], 'string', 'max' => 20],
            [['for_model_class'], 'string', 'max' => 100],
            [['route_name', 'plat_cust_no', 'rand_key', 'serial_no', 'technology_message', 'deleted_at', 'created_by', 'updated_by', 'resp', 'ret_code', 'ret_msg', 'for_model_class', 'for_model_id'], 'default', 'value' => null],
            [['status'], 'default', 'value' => 10],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => Yii::t('app', 'ID'),
            'trans_id' => Yii::t('app', '请求业务流水号'),
            'route' => Yii::t('app', '接口地址'),
            'route_name' => Yii::t('app', '接口地址说明'),
            'version' => Yii::t('app', '版本'),
            'plat_no' => Yii::t('app', '平台编号'),
            'plat_cust_no' => Yii::t('app', '客户编号'),
            'rand_key' => Yii::t('app', '随机密钥'),
            'pre_encryption_data' => Yii::t('app', '加密前请求数据'),
            'serial_no' => Yii::t('app', '技术报文序列号'),
            'technology_message' => Yii::t('app', '技术报文'),
            'created_at' => Yii::t('app', 'Created At'),
            'updated_at' => Yii::t('app', 'Updated At'),
            'deleted_at' => Yii::t('app', 'Deleted At'),
            'created_by' => Yii::t('app', 'Created By'),
            'updated_by' => Yii::t('app', 'Updated By'),
            'status' => Yii::t('app', 'Status'),
            'resp' => Yii::t('app', '响应信息'),
            'ret_code' => Yii::t('app', '返回码'),
            'ret_msg' => Yii::t('app', '返回结果描述'),
            'for_model_class' => Yii::t('app', '对应的模型'),
            'for_model_id' => Yii::t('app', '对应的模型ID'),
        ];
    }
}
